//package com.emily.test.controller;
//
//import com.alibaba.fastjson.JSONObject;
//import com.emily.test.constant.ReturnValueConstants;
//import com.emily.test.controller.result.ResponseResult;
//import com.emily.test.model.DTo;
//import com.emily.test.model.TCompany;
//import com.emily.test.model.TUser;
//import com.emily.test.service.TUserService;
//import com.emily.test.utils.ConstentUtil;
//import com.emily.test.utils.CookieUtils;
//import com.emily.test.utils.MD5Utils;
//import com.emily.test.utils.TokenUtil;
//import io.swagger.annotations.Api;
//import io.swagger.annotations.ApiImplicitParam;
//import io.swagger.annotations.ApiImplicitParams;
//import io.swagger.annotations.ApiOperation;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.http.MediaType;
//import org.springframework.web.bind.annotation.*;
//
//import javax.servlet.http.HttpServletRequest;
//import javax.servlet.http.HttpServletResponse;
//
//@RestController
//@CrossOrigin(origins = "*", maxAge = 3600)
//@RequestMapping(value = "userRegisterController")
//@Api(value = "userRegisterController", description = "userRegisterController接口类", position = 1, produces = MediaType.APPLICATION_JSON_VALUE)
//public class TUserRegisterController {
//
//    @Autowired
//    private TUserService tUserService;
//
////    /**
////     * 用户注册
////     * @param jsonObject
////     * @param request
////     * @param response
//     * @return
////     */
////    @ApiOperation(value="用户注册", notes="用户注册")
////    @ApiImplicitParams({
////            @ApiImplicitParam(name = "loginName", value = "登录名",required = true),
////            @ApiImplicitParam(name = "password", value = "密码",required = true),
////            @ApiImplicitParam(name = "userName", value = "用户名",required = true),
////            @ApiImplicitParam(name = "email", value = "电子邮箱"),
////            @ApiImplicitParam(name = "phone", value = "联系方式",required = true),
////            @ApiImplicitParam(name = "sex", value = "性别"),
////            @ApiImplicitParam(name = "age", value = "年龄"),
////            @ApiImplicitParam(name = "state", value = "启用状态：1、启用；0、禁用；2、删除状态"),
////            @ApiImplicitParam(name = "serial", value = "显示顺序"),
////            @ApiImplicitParam(name = "companyCode", value = "公司code"),
////            @ApiImplicitParam(name = "description", value = "备注"),
////            @ApiImplicitParam(name = "createTime", value = "创建时间"),
////            @ApiImplicitParam(name = "updateTime", value = "修改时间")
////    })
////    @PostMapping(value = "userRegister")
////    @ResponseBody
////    public ResponseResult userRegister(@RequestBody JSONObject jsonObject,
////                                    HttpServletRequest request, HttpServletResponse response) throws Exception {
////
////        TUser tUser= (TUser) ConstentUtil.json2Object(jsonObject,TUser.class);
////        //登录名不允许为空
////        if(ConstentUtil.isEmpty(tUser.getLoginName())){
////            return ResponseResult.fail("登录名"+ReturnValueConstants.IS_NOT_ALLOW_NULL);
////        }
////        //密码不能为空
////        if(ConstentUtil.isEmpty(tUser.getPassword())){
////            return ResponseResult.fail("密码"+ReturnValueConstants.IS_NOT_ALLOW_NULL);
////        }
////        //用户名不能为空
////        if(ConstentUtil.isEmpty(tUser.getUserName())){
////            return ResponseResult.fail("用户名"+ReturnValueConstants.IS_NOT_ALLOW_NULL);
////        }
////        //电话不能为空
////        if(ConstentUtil.isEmpty(tUser.getPhone())){
////            return ResponseResult.fail("电话"+ReturnValueConstants.IS_NOT_ALLOW_NULL);
////        }
////
////        //登录名不允许已经存在
////
////
////        return null;
////    }
//}
